<?php
/*
Template Name: Rented Books 
*/
?>

<?php get_header(); ?>


<?php 
$type = 'library';
$args=array(
  'post_type' => $type,
  'post_status' => 'publish',
  'paged' => $paged,
  'posts_per_page' => 10,
  'caller_get_posts'=> 1,
  'meta_query' => array(
  array(
			'key' => 'wpbl_availablity',
			'value' => 'Rented'
		)
  )
);
$temp = $wp_query;  // assign orginal query to temp variable for later use   
$wp_query = null;
$wp_query = new WP_Query($args); 
?>	
<?php

 get_template_part( 'loop', 'page-user-search' );?>
	<?php
	function library_pages_links(){
    if(function_exists('pagination')) { pagination(); }
	}
	library_pages_links();
    ?>

<?php get_footer(); ?>